-- add_artifact
-- create by shuzy
-- 穿戴神器效果提升N%，最少提升1点

return {
    apply = function(prop, baseValue)
        -- 提升的百分比
        local v = prop[3];

        if v == 0 or baseValue <= 0 then
            return baseValue;
        end

        -- 最少提升1点
        local add = math.modf(baseValue * v / 1000);
        local min_add = 1;

        return baseValue + math.max(min_add, add);
    end,

    record = function(target, prop, path)
        return false;
    end 
};